{% extends "base.html" %}
{% set active_page = "leaderboard" %}
{% set page_title = "Leaderboard - See biggest miners" %}
{% block body %}
<script>
$(document).ready(function() {
    $("#roundSummary").tablesorter({
      textExtraction: function(node) {
        var attr = $(node).attr('data-sort-value');
        if (typeof attr !== 'undefined' && attr !== false) {
          return attr;
        }
        return $(node).text(); 
      } 
    });
});
</script>
<div class="row page-header">
  <h2>General Network Data</h2>
  <br>
  <div class="col-lg-12">
    <table class="table table-striped table-hover table-responsive tablesorter" id="roundSummary">
      <thead>
        <tr>
          <th>Network</th>
          <th>Difficulty</th>
          <th>Blockheight</th>
          <th>Reward</th>
        </tr>
      </thead>
      <tbody>
      {% for currency, data in network_data.iteritems() %}
        <tr>
          <td>{{ currency.name }}</td>
          <td>{{ data['difficulty'] | comma }}</td>
          <td>{{ data['height'] | comma }}</td>
          <td>{{ data['reward'] | comma }}</td>
        </tr>
      {% endfor %}
      </tbody>
    </table>
  </div>
</div>
{% endblock %}
